﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Finance/FinanceMaster.master" AutoEventWireup="true" 
	CodeBehind="CommTemplateEmailEditor.aspx.cs" Inherits="WebApplication.Finance.CommTemplateEmailEditor" Theme="BaselineTheme" %>

<%@ Register src="../Controls/PageHeadingBarCtrl.ascx" tagname="PageHeadingBarCtrl" tagprefix="uc1" %>

<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit.HTMLEditor" tagprefix="cc1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
<style type="text/css">
.keyLabel
{
	font-weight:bold; 
	vertical-align:top;
	font-family:Arial;
	font-size:12pt;
}
.keyDescription
{
	vertical-align:top;
	font-family:Arial;
	font-size:12pt;
}
.fieldsPanel
{
	margin:auto;
	width:460px;
	border-bottom-style:solid; 
	border-bottom-width:4px; 
	border-bottom-color:Red;
}
</style>
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

<!-- Heading bar -->
<div style="margin:auto; margin-top:0px; width:840px;">
	<uc1:PageHeadingBarCtrl ID="pageHeadingBarCtrl" runat="server" Title="SMS and Email Template Editor" />
</div>

<!-- Editing controls -->
<asp:Panel runat="server" CssClass="panelStyle840" ID="pnlControls">
<table align="center" border="0" style="width:500px; text-align:left;">
	<asp:UpdatePanel UpdateMode="Always" runat="server">
	<ContentTemplate>
	<tr>
		<td class="SilverLabel">Name:</td>
		<td><asp:TextBox ID="txtName" MaxLength="50" runat="server" Width="300px" />
			<asp:RequiredFieldValidator ControlToValidate="txtName" ID="valName" runat="server" ErrorMessage="Name required"></asp:RequiredFieldValidator>
		</td>
	</tr>
	</ContentTemplate>
	</asp:UpdatePanel>
	<asp:UpdatePanel ID="UpdatePanel1" UpdateMode="Always" runat="server">
	<ContentTemplate>	
	<tr>
		<td class="SilverLabel" style="vertical-align:top;">Body:</td>
		<td><cc1:Editor ID="richEditor" runat="server" Height="400px" NoScript="True" /></td>
	</tr>
	</ContentTemplate>
	</asp:UpdatePanel>
	<tr>
		<td></td>
		<td style="text-align:right;">
			<asp:Button ID="butTest" runat="server" Text="Test..." OnClick="butTest_Click" />
			<asp:Button ID="butSave" runat="server" Text="Save" OnClick="butSave_Click" />
			<asp:Button ID="butRevert" runat="server" Text="Revert" OnClick="butRevert_Click" CausesValidation="false" />
		</td>
	</tr>
</table>
</asp:Panel>

<!-- Links -->
<div style="margin:auto; margin-top:10px; width:500px; text-align:right">
	<asp:HyperLink ID="HypButton1" runat="server" CssClass="BaselineLinkStyle" Text="Templates..." NavigateUrl="~/Finance/CommTemplates.aspx" />
</div>

<!-- Update progress -->
<asp:UpdateProgress ID="updateProgress1" runat="server" DisplayAfter="500">
<ProgressTemplate>
	<div class="pnlProgressStyle"><h4>Loading data.  Please wait...</h4></div>
</ProgressTemplate>
</asp:UpdateProgress>

</asp:Content>
